﻿namespace TwoItems
{
    public class ExampleInfo
    {
        public int Id { get; set; }

        public double U1 { get; set; }
        public double O1 { get; set; }
        public double E1 { get; set; }
        public double SD1 { get; set; }
        public double Var1
        {
            get
            {
                return SD1 * SD1;
            }
        }
        public double E1_E { get; set; }
        public double SD1_E { get; set; }
        public double Var1_E
        {
            get
            {
                return SD1_E * SD1_E;
            }
        }

        public double U2 { get; set; }
        public double O2 { get; set; }
        public double E2 { get; set; }
        public double SD2 { get; set; }
        public double Var2
        {
            get
            {
                return SD2 * SD2;
            }
        }
        public double E2_E { get; set; }
        public double SD2_E { get; set; }
        public double Var2_E
        {
            get
            {
                return SD2_E * SD2_E;
            }
        }
        public double R12 { get; set; }
        public double R21 { get; set; }

        public double QC1 { get; set; }
        public double QC2 { get; set; }

        public double QD1 { get; set; }
        public double QD2 { get; set; }

        public double PC1 { get; set; }
        public double PC2 { get; set; }
        public double PC { get; set; }

        public double PD1 { get; set; }
        public double PD2 { get; set; }
        public double PD { get; set; }

        //均衡概率
        public double Prob1 { get; set; }
        public double Prob2 { get; set; }

        public double UO1
        {
            get { return U1 / (U1 + O1); }
        }
        public double UO2
        {
            get { return U2 / (U2 + O2); }
        }
        public double MaxQC1 { get; set; }
        public double MaxQC2 { get; set; }

        public double MaxQD1 { get; set; }
        public double MaxQD2 { get; set; }
    }

    public struct DataStruct
    {
        public double U1 { get; set; }
        public double O1 { get; set; }
        public double E1 { get; set; }
        public double SD1 { get; set; }
        public double E1_E { get; set; }
        public double SD1_E { get; set; }

        public double U2 { get; set; }
        public double O2 { get; set; }
        public double E2 { get; set; }
        public double SD2 { get; set; }
        public double E2_E { get; set; }
        public double SD2_E { get; set; }

        public double R12 { get; set; }
        public double R21 { get; set; }

        public double QC1 { get; set; }
        public double QC2 { get; set; }

        public double QD1 { get; set; }
        public double QD2 { get; set; }

        public double PC1 { get; set; }
        public double PC2 { get; set; }
        public double PC { get; set; }

        public double PD1 { get; set; }
        public double PD2 { get; set; }
        public double PD { get; set; }
    }
}
